Hierarchical models using self organizing learning topologies

ABSTRACT

In one embodiment, a device in a network maintains a plurality of anomaly detection models for different sets of aggregated traffic data regarding traffic in the network. The device determines a measure of confidence in a particular one of the anomaly detection models that evaluates a particular set of aggregated traffic data. The device dynamically replaces the particular anomaly detection model with a second anomaly detection model configured to evaluate the particular set of aggregated traffic data and has a different model capacity than that of the particular anomaly detection model. The device provides an anomaly event notification to a supervisory controller based on a combined output of the second anomaly detection model and of one or more of the anomaly detection models in the plurality of anomaly detection models.

RELATED APPLICATIONS

This application is a Continuation Application of U.S. patentapplication Ser. No. 15/176,652, filed Jun. 8, 2016, entitled“HIERARCHICAL MODELS USING SELF ORGANIZING LEARNING TOPOLOGIES,” bySavalle et al., which claims priority to U.S. Provisional ApplicationNo. 62/313,322, filed Mar. 25, 2016, entitled “HIERARCHICAL MODELS USINGSELF ORGANIZING LEARNING TOPOLOGIES,” by Savalle et al., the contents ofwhich are hereby incorporated by reference.

TECHNICAL FIELD

The present disclosure relates generally to computer networks, and, moreparticularly, to hierarchical models organizing learning topologies in acomputer network.

BACKGROUND

Generally, Internet Behavioral Analytics (IBA) refers to the use ofadvanced analytics coupled with various networking technologies, todetect anomalies in a network. Such anomalies may include, for example,network attacks, malware, misbehaving and misconfigured devices, and thelike. For example, the ability to model the behavior of a device (e.g.,a host, networking switch, router, etc.) allows for the detection ofmalware, which is complimentary to the use of firewalls that use staticsignature. Observing behavioral changes (e.g., deviation from modeledbehavior) using flows records, deep packet inspection, and the like,lows for the detection of an anomaly such as an horizontal movement(e.g. propagation of a malware, . . . ) or an attempt to performinformation exfiltration, prompting the system to take remediationactions automatically.

One type of network attack that is of particular concern in the contextof computer networks is a Denial of Service (DoS) attack. In general,the goal of a DoS attack is to prevent legitimate use of the servicesavailable on the network. For example, a DoS jamming attack mayartificially introduce interference into the network, thereby causingcollisions with legitimate traffic and preventing message decoding. Inanother example, a DoS attack may attempt to overwhelm the network'sresources by flooding the network with requests, to prevent legitimaterequests from being processed. A DoS attack may also be distributed, toconceal the presence of the attack. For example, a distributed DoS(DDoS) attack may involve multiple attackers sending malicious requests,making it more difficult to distinguish when an attack is underway. Whenviewed in isolation, a particular one of such a request may not appearto be malicious. However, in the aggregate, the requests may overload aresource, thereby impacting legitimate requests sent to the resource.

Botnets represent one way in which a DDoS attack may be launched againsta network. In a botnet, a subset of the network devices may be infectedwith malicious software, thereby allowing the devices in the botnet tobe controlled by a single master. Using this control, the master canthen coordinate the attack against a given network resource.

BRIEF DESCRIPTION OF THE DRAWINGS

The embodiments herein may be better understood by referring to thefollowing description in conjunction with the accompanying drawings inwhich like reference numerals indicate identically or functionallysimilar elements, of which:

FIGS. 1A-1B illustrate an example communication network;

FIG. 2 illustrates an example network device/node;

FIG. 3 illustrates an example self learning network (SLN)infrastructure;

FIG. 4 illustrates an example distributed learning agent (DLA);

FIGS. 5A-5E illustrate an example of a DLA dynamically swapping anomalydetection models;

FIGS. 6A-6D illustrate an example of a DLA using model competitionbucket groups;

FIGS. 7A-7C illustrate examples of anomaly score reports;

FIGS. 8A-8B illustrate examples of a DLA sharing anomaly scoredistributions;

FIGS. 9A-9D illustrate examples of DLAs sharing anomaly detectionmodels; and

FIG. 10 illustrates an example simplified procedure for using anomalydetection models.

DESCRIPTION OF EXAMPLE EMBODIMENTS Overview

According to one or more embodiments of the disclosure, a device in anetwork maintains a plurality of anomaly detection models for differentsets of aggregated traffic data regarding traffic in the network. Thedevice determines a measure of confidence in a particular one of theanomaly detection models that evaluates a particular set of aggregatedtraffic data. The device dynamically replaces the particular anomalydetection model with a second anomaly detection model configured toevaluate the particular set of aggregated traffic data and has adifferent model capacity than that of the particular anomaly detectionmodel. The device provides an anomaly event notification to asupervisory controller based on a combined output of the second anomalydetection model and of one or more of the anomaly detection models inthe plurality of anomaly detection models.

Description

A computer network is a geographically distributed collection of nodesinterconnected by communication links and segments for transporting databetween end nodes, such as personal computers and workstations, or otherdevices, such as sensors, etc. Many types of networks are available,with the types ranging from local area networks (LANs) to wide areanetworks (WANs). LANs typically connect the nodes over dedicated privatecommunications links located in the same general physical location, suchas a building or campus. WANs, on the other hand, typically connectgeographically dispersed nodes over long-distance communications links,such as common carrier telephone lines, optical lightpaths, synchronousoptical networks (SONET), or synchronous digital hierarchy (SDH) links,or Powerline Communications (PLC) such as IEEE 61334, IEEE P1901.2, andothers. The Internet is an example of a WAN that connects disparatenetworks throughout the world, providing global communication betweennodes on various networks. The nodes typically communicate over thenetwork by exchanging discrete frames or packets of data according topredefined protocols, such as the Transmission Control Protocol/InternetProtocol (TCP/IP). In this context, a protocol consists of a set ofrules defining how the nodes interact with each other. Computer networksmay be further interconnected by an intermediate network node, such as arouter, to extend the effective “size” of each network.

Smart object networks, such as sensor networks, in particular, are aspecific type of network having spatially distributed autonomous devicessuch as sensors, actuators, etc., that cooperatively monitor physical orenvironmental conditions at different locations, such as, e.g.,energy/power consumption, resource consumption (e.g., water/gas/etc. foradvanced metering infrastructure or “AMI” applications) temperature,pressure, vibration, sound, radiation, motion, pollutants, etc. Othertypes of smart objects include actuators, e.g., responsible for turningon/off an engine or perform any other actions. Sensor networks, a typeof smart object network, are typically shared-media networks, such aswireless or PLC networks. That is, in addition to one or more sensors,each sensor device (node) in a sensor network may generally be equippedwith a radio transceiver or other communication port such as PLC, amicrocontroller, and an energy source, such as a battery. Often, smartobject networks are considered field area networks (FANs), neighborhoodarea networks (NANs), personal area networks (PANs), etc. Generally,size and cost constraints on smart object nodes (e.g., sensors) resultin corresponding constraints on resources such as energy, memory,computational speed and bandwidth.

FIG. 1A is a schematic block diagram of an example computer network 100illustratively comprising nodes/devices, such as a plurality ofrouters/devices interconnected by links or networks, as shown. Forexample, customer edge (CE) routers 110 may be interconnected withprovider edge (PE) routers 120 (e.g., PE-1, PE-2, and PE-3) in order tocommunicate across a core network, such as an illustrative networkbackbone 130. For example, routers 110, 120 may be interconnected by thepublic Internet, a multiprotocol label switching (MPLS) virtual privatenetwork (VPN), or the like. Data packets 140 (e.g., traffic/messages)may be exchanged among the nodes/devices of the computer network 100over links using predefined network communication protocols such as theTransmission Control Protocol/Internet Protocol (TCP/IP), User DatagramProtocol (UDP), Asynchronous Transfer Mode (ATM) protocol, Frame Relayprotocol, or any other suitable protocol. Those skilled in the art willunderstand that any number of nodes, devices, links, etc. may be used inthe computer network, and that the view shown herein is for simplicity.

In some implementations, a router or a set of routers may be connectedto a private network (e.g., dedicated leased lines, an optical network,etc.) or a virtual private network (VPN), such as an MPLS VPN thanks toa carrier network, via one or more links exhibiting very differentnetwork and service level agreement characteristics. For the sake ofillustration, a given customer site may fall under any of the followingcategories:

1.) Site Type A: a site connected to the network (e.g., via a private orVPN link) using a single CE router and a single link, with potentially abackup link (e.g., a 3G/4G/LTE backup connection). For example, aparticular CE router 110 shown in network 100 may support a givencustomer site, potentially also with a backup link, such as a wirelessconnection.

2.) Site Type B: a site connected to the network using two MPLS VPNlinks (e.g., from different Service Providers), with potentially abackup link (e.g., a 3G/4G/LTE connection). A site of type B may itselfbe of different types:

2a.) Site Type B1: a site connected to the network using two MPLS VPNlinks (e.g., from different Service Providers), with potentially abackup link (e.g., a 3G/4G/LTE connection).

2b.) Site Type B2: a site connected to the network using one MPLS VPNlink and one link connected to the public Internet, with potentially abackup link (e.g., a 3G/4G/LTE connection). For example, a particularcustomer site may be connected to network 100 via PE-3 and via aseparate Internet connection, potentially also with a wireless backuplink.

2c.) Site Type B3: a site connected to the network using two linksconnected to the public Internet, with potentially a backup link (e.g.,a 3G/4G/LTE connection).

Notably, MPLS VPN links are usually tied to a committed service levelagreement, whereas Internet links may either have no service levelagreement at all or a loose service level agreement (e.g., a “GoldPackage” Internet service connection that guarantees a certain level ofperformance to a customer site).

3.) Site Type C: a site of type B (e.g., types B1, B2 or B3) but withmore than one CE router (e.g., a first CE router connected to one linkwhile a second CE router is connected to the other link), andpotentially a backup link (e.g., a wireless 3G/4G/LTE backup link). Forexample, a particular customer site may include a first CE router 110connected to PE-2 and a second CE router 110 connected to PE-3.

FIG. 1B illustrates an example of network 100 in greater detail,according to various embodiments. As shown, network backbone 130 mayprovide connectivity between devices located in different geographicalareas and/or different types of local networks. For example, network 100may comprise local/branch networks 160, 162 that include devices/nodes10-16 and devices/nodes 18-20, respectively, as well as a datacenter/cloud environment 150 that includes servers 152-154. Notably,local networks 160-162 and data center/cloud environment 150 may belocated in different geographic locations.

Servers 152-154 may include, in various embodiments, a networkmanagement server (NMS), a dynamic host configuration protocol (DHCP)server, a constrained application protocol (CoAP) server, an outagemanagement system (OMS), an application policy infrastructure controller(APIC), an application server, etc. As would be appreciated, network 100may include any number of local networks, data centers, cloudenvironments, devices/nodes, servers, etc.

In some embodiments, the techniques herein may be applied to othernetwork topologies and configurations. For example, the techniquesherein may be applied to peering points with high-speed links, datacenters, etc.

In various embodiments, network 100 may include one or more meshnetworks, such as an Internet of Things network. Loosely, the term“Internet of Things” or “IoT” refers to uniquely identifiable objects(things) and their virtual representations in a network-basedarchitecture. In particular, the next frontier in the evolution of theInternet is the ability to connect more than just computers andcommunications devices, but rather the ability to connect “objects” ingeneral, such as lights, appliances, vehicles, heating, ventilating, andair-conditioning (HVAC), windows and window shades and blinds, doors,locks, etc. The “Internet of Things” thus generally refers to theinterconnection of objects (e.g., smart objects), such as sensors andactuators, over a computer network (e.g., via IP), which may be thepublic Internet or a private network.

Notably, shared-media mesh networks, such as wireless or PLC networks,etc., are often on what is referred to as Low-Power and Lossy Networks(LLNs), which are a class of network in which both the routers and theirinterconnect are constrained: LLN routers typically operate withconstraints, e.g., processing power, memory, and/or energy (battery),and their interconnects are characterized by, illustratively, high lossrates, low data rates, and/or instability. LLNs are comprised ofanything from a few dozen to thousands or even millions of LLN routers,and support point-to-point traffic (between devices inside the LLN),point-to-multipoint traffic (from a central control point such at theroot node to a subset of devices inside the LLN), andmultipoint-to-point traffic (from devices inside the LLN towards acentral control point). Often, an IoT network is implemented with anLLN-like architecture. For example, as shown, local network 160 may bean LLN in which CE-2 operates as a root node for nodes/devices 10-16 inthe local mesh, in some embodiments.

In contrast to traditional networks, LLNs face a number of communicationchallenges. First, LLNs communicate over a physical medium that isstrongly affected by environmental conditions that change over time.Some examples include temporal changes in interference (e.g., otherwireless networks or electrical appliances), physical obstructions(e.g., doors opening/closing, seasonal changes such as the foliagedensity of trees, etc.), and propagation characteristics of the physicalmedia (e.g., temperature or humidity changes, etc.). The time scales ofsuch temporal changes can range between milliseconds (e.g.,transmissions from other transceivers) to months (e.g., seasonal changesof an outdoor environment). In addition, LLN devices typically uselow-cost and low-power designs that limit the capabilities of theirtransceivers. In particular, LLN transceivers typically provide lowthroughput. Furthermore, LLN transceivers typically support limited linkmargin, making the effects of interference and environmental changesvisible to link and network protocols. The high number of nodes in LLNsin comparison to traditional networks also makes routing, quality ofservice (QoS), security, network management, and traffic engineeringextremely challenging, to mention a few.

FIG. 2 is a schematic block diagram of an example node/device 200 thatmay be used with one or more embodiments described herein, e.g., as anyof the computing devices shown in FIGS. 1A-1B, particularly the PErouters 120, CE routers 110, nodes/device 10-20, servers 152-154 (e.g.,a network controller located in a data center, etc.), any othercomputing device that supports the operations of network 100 (e.g.,switches, etc.), or any of the other devices referenced below. Thedevice 200 may also be any other suitable type of device depending uponthe type of network architecture in place, such as IoT nodes, etc.Device 200 comprises one or more network interfaces 210, one or moreprocessors 220, and a memory 240 interconnected by a system bus 250, andis powered by a power supply 260.

The network interfaces 210 include the mechanical, electrical, andsignaling circuitry for communicating data over physical links coupledto the network 100. The network interfaces may be configured to transmitand/or receive data using a variety of different communicationprotocols. Notably, a physical network interface 210 may also be used toimplement one or more virtual network interfaces, such as for virtualprivate network (VPN) access, known to those skilled in the art.

The memory 240 comprises a plurality of storage locations that areaddressable by the processor(s) 220 and the network interfaces 210 forstoring software programs and data structures associated with theembodiments described herein. The processor 220 may comprise necessaryelements or logic adapted to execute the software programs andmanipulate the data structures 245. An operating system 242 (e.g., theInternetworking Operating System, or IOS®, of Cisco Systems, Inc.,another operating system, etc.), portions of which are typicallyresident in memory 240 and executed by the processor(s), functionallyorganizes the node by, inter alia, invoking network operations insupport of software processors and/or services executing on the device.These software processors and/or services may comprise routing process244 (e.g., routing services) and illustratively, a self learning network(SLN) process 248, as described herein, any of which may alternativelybe located within individual network interfaces.

It will be apparent to those skilled in the art that other processor andmemory types, including various computer-readable media, may be used tostore and execute program instructions pertaining to the techniquesdescribed herein. Also, while the description illustrates variousprocesses, it is expressly contemplated that various processes may beembodied as modules configured to operate in accordance with thetechniques herein (e.g., according to the functionality of a similarprocess). Further, while processes may be shown and/or describedseparately, those skilled in the art will appreciate that processes maybe routines or modules within other processes.

Routing process/services 244 include computer executable instructionsexecuted by processor 220 to perform functions provided by one or morerouting protocols, such as the Interior Gateway Protocol (IGP) (e.g.,Open Shortest Path First, “OSPF,” andIntermediate-System-to-Intermediate-System, “IS-IS”), the Border GatewayProtocol (BGP), etc., as will be understood by those skilled in the art.These functions may be configured to manage a forwarding informationdatabase including, e.g., data used to make forwarding decisions. Inparticular, changes in the network topology may be communicated amongrouters 200 using routing protocols, such as the conventional OSPF andIS-IS link-state protocols (e.g., to “converge” to an identical view ofthe network topology).

Notably, routing process 244 may also perform functions related tovirtual routing protocols, such as maintaining VRF instance, ortunneling protocols, such as for MPLS, generalized MPLS (GMPLS), etc.,each as will be understood by those skilled in the art. Also, EVPN,e.g., as described in the IETF Internet Draft entitled “BGP MPLS BasedEthernet VPN” <draft-ietf-12vpn-evpn>, introduce a solution formultipoint L2VPN services, with advanced multi-homing capabilities,using BGP for distributing customer/client media access control (MAC)address reach-ability information over the core MPLS/IP network.

SLN process 248 includes computer executable instructions that, whenexecuted by processor(s) 220, cause device 200 to perform anomalydetection functions as part of an anomaly detection infrastructurewithin the network. In general, anomaly detection attempts to identifypatterns that do not conform to an expected behavior. For example, inone embodiment, the anomaly detection infrastructure of the network maybe operable to detect network attacks (e.g., DDoS attacks, the use ofmalware such as viruses, rootkits, etc.). However, anomaly detection inthe context of computer networking typically presents a number ofchallenges: 1.) a lack of a ground truth (e.g., examples of normal vs.abnormal network behavior), 2.) being able to define a “normal” regionin a highly dimensional space can be challenging, 3.) the dynamic natureof the problem due to changing network behaviors/anomalies, 4.)malicious behaviors such as malware, viruses, rootkits, etc. may adaptin order to appear “normal,” and 5.) differentiating between noise andrelevant anomalies is not necessarily possible from a statisticalstandpoint, but typically also requires domain knowledge.

Anomalies may also take a number of forms in a computer network: 1.)point anomalies (e.g., a specific data point is abnormal compared toother data points), 2.) contextual anomalies (e.g., a data point isabnormal in a specific context but not when taken individually), or 3.)collective anomalies (e.g., a collection of data points is abnormal withregards to an entire set of data points). Generally, anomaly detectionrefers to the ability to detect an anomaly that could be triggered bythe presence of malware attempting to access data (e.g., dataexfiltration), spyware, ransom-ware, etc. and/or non-malicious anomaliessuch as misconfigurations or misbehaving code. Particularly, an anomalymay be raised in a number of circumstances:

-   -   Security threats: the presence of a malware using unknown        attacks patterns (e.g., no static signatures) may lead to        modifying the behavior of a host in terms of traffic patterns,        graphs structure, etc. Machine learning processes may detect        these types of anomalies using advanced approaches capable of        modeling subtle changes or correlation between changes (e.g.,        unexpected behavior) in a highly dimensional space. Such        anomalies are raised in order to detect, e.g., the presence of a        0-day malware, malware used to perform data ex-filtration thanks        to a Command and Control (C2) channel, or even to trigger        (Distributed) Denial of Service (DoS) such as DNS reflection,        UDP flood, HTTP recursive get, etc. In the case of a (D)DoS,        although technical an anomaly, the term “DoS” is usually used.        SLN process 248 may detect malware based on the corresponding        impact on traffic, host models, graph-based analysis, etc., when        the malware attempts to connect to a C2 channel, attempts to        move laterally, or exfiltrate information using various        techniques.    -   Misbehaving devices: a device such as a laptop, a server of a        network device (e.g., storage, router, switch, printer, etc.)        may misbehave in a network for a number of reasons: 1.) a user        using a discovery tool that performs (massive) undesirable        scanning in the network (in contrast with a lawful scanning by a        network management tool performing device discovery), 2.) a        software defect (e.g. a switch or router dropping packet because        of a corrupted RIB/FIB or the presence of a persistent loop by a        routing protocol hitting a corner case).    -   Dramatic behavior change: the introduction of a new networking        or end-device configuration, or even the introduction of a new        application may lead to dramatic behavioral changes. Although        technically not anomalous, an SLN-enabled node having computed        behavioral model(s) may raise an anomaly when detecting a brutal        behavior change. Note that in such as case, although an anomaly        may be raised, a learning system such as SLN is expected to        learn the new behavior and dynamically adapts according to        potential user feedback.    -   Misconfigured devices: a configuration change may trigger an        anomaly: a misconfigured access control list (ACL), route        redistribution policy, routing policy, QoS policy maps, or the        like, may have dramatic consequences such a traffic black-hole,        QoS degradation, etc. SLN process 248 may advantageously        identify these forms of misconfigurations, in order to be        detected and fixed.

In various embodiments, SLN process 248 may utilize machine learningtechniques, to perform anomaly detection in the network. In general,machine learning is concerned with the design and the development oftechniques that take as input empirical data (such as network statisticsand performance indicators), and recognize complex patterns in thesedata. One very common pattern among machine learning techniques is theuse of an underlying model M, whose parameters are optimized forminimizing the cost function associated to M, given the input data. Forinstance, in the context of classification, the model M may be astraight line that separates the data into two classes (e.g., labels)such that M=a*x+b*y+c and the cost function would be the number ofmisclassified points. The learning process then operates by adjustingthe parameters a,b,c such that the number of misclassified points isminimal. After this optimization phase (or learning phase), the model Mcan be used very easily to classify new data points. Often, M is astatistical model, and the cost function is inversely proportional tothe likelihood of M, given the input data.

Computational entities that rely on one or more machine learningtechniques to perform a task for which they have not been explicitlyprogrammed to perform are typically referred to as learning machines. Inparticular, learning machines are capable of adjusting their behavior totheir environment. For example, a learning machine may dynamically makefuture predictions based on current or prior network measurements, maymake control decisions based on the effects of prior control commands,etc.

For purposes of anomaly detection in a network, a learning machine mayconstruct a model of normal network behavior, to detect data points thatdeviate from this model. For example, a given model (e.g., a supervised,un-supervised, or semi-supervised model) may be used to generate andreport anomaly scores to another device. Example machine learningtechniques that may be used to construct and analyze such a model mayinclude, but are not limited to, nearest neighbor (NN) techniques (e.g.,k-NN models, replicator NN models, etc.), statistical techniques (e.g.,Bayesian networks, etc.), clustering techniques (e.g., k-means, etc.),neural networks (e.g., reservoir networks, artificial neural networks,etc.), support vector machines (SVMs), or the like.

One class of machine learning techniques that is of particular use inthe context of anomaly detection is clustering. Generally speaking,clustering is a family of techniques that seek to group data accordingto some typically predefined notion of similarity. For instance,clustering is a very popular technique used in recommender systems forgrouping objects that are similar in terms of people's taste (e.g.,because you watched X, you may be interested in Y, etc.). Typicalclustering algorithms are k-means, density based spatial clustering ofapplications with noise (DBSCAN) and mean-shift, where a distance to acluster is computed with the hope of reflecting a degree of anomaly(e.g., using a Euclidian distance and a cluster based local outlierfactor that takes into account the cluster density).

Replicator techniques may also be used for purposes of anomalydetection. Such techniques generally attempt to replicate an input in anunsupervised manner by projecting the data into a smaller space (e.g.,compressing the space, thus performing some dimensionality reduction)and then reconstructing the original input, with the objective ofkeeping the “normal” pattern in the low dimensional space. Exampletechniques that fall into this category include principal componentanalysis (PCA) (e.g., for linear models), multi-layer perceptron (MLP)ANNs (e.g., for non-linear models), and replicating reservoir networks(e.g., for non-linear models, typically for time series).

According to various embodiments, SLN process 248 may also usegraph-based models for purposes of anomaly detection. Generallyspeaking, a graph-based model attempts to represent the relationshipsbetween different entities as a graph of nodes interconnected by edges.For example, ego-centric graphs have been used to represent therelationship between a particular social networking profile and theother profiles connected to it (e.g., the connected “friends” of a user,etc.). The patterns of these connections can then be analyzed forpurposes of anomaly detection. For example, in the social networkingcontext, it may be considered anomalous for the connections of aparticular profile not to share connections, as well. In other words, aperson's social connections are typically also interconnected. If nosuch interconnections exist, this may be deemed anomalous.

An example self learning network (SLN) infrastructure that may be usedto detect network anomalies is shown in FIG. 3, according to variousembodiments. Generally, network devices may be configured to operate aspart of an SLN infrastructure to detect, analyze, and/or mitigatenetwork anomalies such as network attacks (e.g., by executing SLNprocess 248). Such an infrastructure may include certain network devicesacting as distributed learning agents (DLAs) and one or moresupervisory/centralized devices acting as a supervisory and controlagent (SCA). A DLA may be operable to monitor network conditions (e.g.,router states, traffic flows, etc.), perform anomaly detection on themonitored data using one or more machine learning models, reportdetected anomalies to the SCA, and/or perform local mitigation actions.Similarly, an SCA may be operable to coordinate the deployment andconfiguration of the DLAs (e.g., by downloading software upgrades to aDLA, etc.), receive information from the DLAs (e.g., detectedanomalies/attacks, compressed data for visualization, etc.), provideinformation regarding a detected anomaly to a user interface (e.g., byproviding a webpage to a display, etc.), and/or analyze data regarding adetected anomaly using more CPU intensive machine learning processes.

One type of network attack that is of particular concern in the contextof computer networks is a Denial of Service (DoS) attack. In general,the goal of a DoS attack is to prevent legitimate use of the servicesavailable on the network. For example, a DoS jamming attack mayartificially introduce interference into the network, thereby causingcollisions with legitimate traffic and preventing message decoding. Inanother example, a DoS attack may attempt to overwhelm the network'sresources by flooding the network with requests (e.g., SYN flooding,sending an overwhelming number of requests to an HTTP server, etc.), toprevent legitimate requests from being processed. A DoS attack may alsobe distributed, to conceal the presence of the attack. For example, adistributed DoS (DDoS) attack may involve multiple attackers sendingmalicious requests, making it more difficult to distinguish when anattack is underway. When viewed in isolation, a particular one of such arequest may not appear to be malicious. However, in the aggregate, therequests may overload a resource, thereby impacting legitimate requestssent to the resource.

Botnets represent one way in which a DDoS attack may be launched againsta network. In a botnet, a subset of the network devices may be infectedwith malicious software, thereby allowing the devices in the botnet tobe controlled by a single master. Using this control, the master canthen coordinate the attack against a given network resource.

DoS attacks are relatively easy to detect when they are brute-force(e.g. volumetric), but, especially when highly distributed, they may bedifficult to distinguish from a flash-crowd (e.g., an overload of thesystem due to many legitimate users accessing it at the same time). Thisfact, in conjunction with the increasing complexity of performedattacks, makes the use of “classic” (usually threshold-based) techniquesuseless for detecting them. However, machine learning techniques maystill be able to detect such attacks, before the network or servicebecomes unavailable. For example, some machine learning approaches mayanalyze changes in the overall statistical behavior of the networktraffic (e.g., the traffic distribution among flow flattens when a DDoSattack based on a number of microflows happens). Other approaches mayattempt to statistically characterizing the normal behaviors of networkflows or TCP connections, in order to detect significant deviations.Classification approaches try to extract features of network flows andtraffic that are characteristic of normal traffic or malicious traffic,constructing from these features a classifier that is able todifferentiate between the two classes (normal and malicious).

As shown in FIG. 3, routers CE-2 and CE-3 may be configured as DLAs andserver 152 may be configured as an SCA, in one implementation. In such acase, routers CE-2 and CE-3 may monitor traffic flows, router states(e.g., queues, routing tables, etc.), or any other conditions that maybe indicative of an anomaly in network 100. As would be appreciated, anynumber of different types of network devices may be configured as a DLA(e.g., routers, switches, servers, blades, etc.) or as an SCA.

Assume, for purposes of illustration, that CE-2 acts as a DLA thatmonitors traffic flows associated with the devices of local network 160(e.g., by comparing the monitored conditions to one or moremachine-learning models). For example, assume that device/node 10 sendsa particular traffic flow 302 to server 154 (e.g., an applicationserver, etc.). In such a case, router CE-2 may monitor the packets oftraffic flow 302 and, based on its local anomaly detection mechanism,determine that traffic flow 302 is anomalous. Anomalous traffic flowsmay be incoming, outgoing, or internal to a local network serviced by aDLA, in various cases.

In some cases, traffic 302 may be associated with a particularapplication supported by network 100. Such applications may include, butare not limited to, automation applications, control applications, voiceapplications, video applications, alert/notification applications (e.g.,monitoring applications), communication applications, and the like. Forexample, traffic 302 may be email traffic, HTTP traffic, trafficassociated with an enterprise resource planning (ERP) application, etc.

In various embodiments, the anomaly detection mechanisms in network 100may use Internet Behavioral Analytics (IBA). In general, IBA refers tothe use of advanced analytics coupled with networking technologies, todetect anomalies in the network. Although described later with greaterdetails, the ability to model the behavior of a device (networkingswitch/router, host, etc.) will allow for the detection of malware,which is complementary to the use of a firewall that uses staticsignatures. Observing behavioral changes (e.g., a deviation from modeledbehavior) thanks to aggregated flows records, deep packet inspection,etc., may allow detection of an anomaly such as an horizontal movement(e.g. propagation of a malware, etc.), or an attempt to performinformation exfiltration.

FIG. 4 illustrates an example distributed learning agent (DLA) 400 ingreater detail, according to various embodiments. Generally, a DLA maycomprise a series of modules hosting sophisticated tasks (e.g., as partof an overall SLN process 248). Generally, DLA 400 may communicate withan SCA (e.g., via one or more northbound APIs 402) and any number ofnodes/devices in the portion of the network associated with DLA 400(e.g., via APIs 420, etc.).

In some embodiments, DLA 400 may execute a Network Sensing Component(NSC) 416 that is a passive sensing construct used to collect a varietyof traffic record inputs 426 from monitoring mechanisms deployed to thenetwork nodes. For example, traffic record inputs 426 may include Cisco™Netflow records, application identification information from a Cisco™Network Based Application Recognition (NBAR) process or anotherapplication-recognition mechanism, administrative information from anadministrative reporting tool (ART), local network state informationservice sets, media metrics, or the like.

Furthermore, NSC 416 may be configured to dynamically employ Deep PacketInspection (DPI), to enrich the mathematical models computed by DLA 400,a critical source of information to detect a number of anomalies. Alsoof note is that accessing control/data plane data may be of utmostimportance, to detect a number of advanced threats such as dataexfiltration. NSC 416 may be configured to perform data analysis anddata enhancement (e.g., the addition of valuable information to the rawdata through correlation of different information sources). Moreover,NSC 416 may compute various networking based metrics relevant for theDistributed Learning Component (DLC) 408, such as a large number ofstatistics, some of which may not be directly interpretable by a human.

In some embodiments, DLA 400 may also include DLC 408 that may perform anumber of key operations such as any or all of the following:computation of Self Organizing Learning Topologies (SOLT), computationof “features” (e.g., feature vectors), advanced machine learningprocesses, etc., which DLA 400 may use in combination to perform aspecific set of tasks. In some cases, DLC 408 may include areinforcement learning (RL) engine 412 that uses reinforcement learningto detect anomalies or otherwise assess the operating conditions of thenetwork. Accordingly, RL engine 412 may maintain and/or use any numberof communication models 410 that model, e.g., various flows of trafficin the network. In further embodiments, DLC 408 may use any other formof machine learning techniques, such as those described previously(e.g., supervised or unsupervised techniques, etc.). For example, in thecontext of SLN for security, DLC 408 may perform modeling of traffic andapplications in the area of the network associated with DLA 400. DLC 408can then use the resulting models 410 to detect graph-based and otherforms of anomalies (e.g., by comparing the models with current networkcharacteristics, such as traffic patterns. The SCA may also send updates414 to DLC 408 to update model(s) 410 and/or RL engine 412 (e.g., basedon information from other deployed DLAs, input from a user, etc.).

When present, RL engine 412 may enable a feed-back loop between thesystem and the end user, to automatically adapt the system decisions tothe expectations of the user and raise anomalies that are of interest tothe user (e.g., as received via a user interface of the SCA). In oneembodiment, RL engine 412 may receive a signal from the user in the formof a numerical reward that represents for example the level of interestof the user related to a previously raised event. Consequently the agentmay adapt its actions (e.g. search for new anomalies), to maximize itsreward over time, thus adapting the system to the expectations of theuser. More specifically, the user may optionally provide feedback thanksto a lightweight mechanism (e.g., ‘like’ or ‘dislike’) via the userinterface.

In some cases, DLA 400 may include a threat intelligence processor (TIP)404 that processes anomaly characteristics so as to further assess therelevancy of the anomaly (e.g. the applications involved in the anomaly,location, scores/degree of anomaly for a given model, nature of theflows, or the like). TIP 404 may also generate or otherwise leverage amachine learning-based model that computes a relevance index. Such amodel may be used across the network to select/prioritize anomaliesaccording to the relevancies.

DLA 400 may also execute a Predictive Control Module (PCM) 406 thattriggers relevant actions in light of the events detected by DLC 408. Inorder words, PCM 406 is the decision maker, subject to policy. Forexample, PCM 406 may employ rules that control when DLA 400 is to sendinformation to the SCA (e.g., alerts, predictions, recommended actions,trending data, etc.) and/or modify a network behavior itself. Forexample, PCM 406 may determine that a particular traffic flow should beblocked (e.g., based on the assessment of the flow by TIP 404 and DLC408) and an alert sent to the SCA.

Network Control Component (NCC) 418 is a module configured to triggerany of the actions determined by PCM 406 in the network nodes associatedwith DLA 400. In various embodiments, NCC 418 may communicate thecorresponding instructions 422 to the network nodes using APIs 420(e.g., DQoS interfaces, ABR interfaces, DCAC interfaces, etc.). Forexample, NCC 418 may send mitigation instructions 422 to one or morenodes that instruct the receives to reroute certain anomalous traffic,perform traffic shaping, drop or otherwise “black hole” the traffic, ortake other mitigation steps. In some embodiments, NCC 418 may also beconfigured to cause redirection of the traffic to a “honeypot” devicefor forensic analysis. Such actions may be user-controlled, in somecases, through the use of policy maps and other configurations. Notethat NCC 418 may be accessible via a very flexible interface allowing acoordinated set of sophisticated actions. In further embodiments, API(s)420 of NCC 418 may also gather/receive certain network data 424 from thedeployed nodes such as Cisco™ OnePK information or the like.

The various components of DLA 400 may be executed within a container, insome embodiments, that receives the various data records and otherinformation directly from the host router or other networking device.Doing so prevents these records from consuming additional bandwidth inthe external network. This is a major advantage of such a distributedsystem over centralized approaches that require sending large amount oftraffic records. Furthermore, the above mechanisms afford DLA 400additional insight into other information such as control plane packetand local network states that are only available on premise. Note alsothat the components shown in FIG. 4 may have a low footprint, both interms of memory and CPU. More specifically, DLA 400 may use lightweighttechniques to compute features, identify and classify observation data,and perform other functions locally without significantly impacting thefunctions of the host router or other networking device.

As noted above, edge devices may perform anomaly detection by analyzingtraffic flows. In the context of building anomaly detection models atthe network edge from network traffic, there is a central tradeoffbetween using very specific models and very general models. Notably,models constructed from all of the traffic for a given application arevery general in nature and can get a lot of samples if there is enoughtraffic for the application. As a consequence, these models tend to berather confident and accurate in modeling many different behaviors atthe same time. Such models are essential to detecting very strongnetwork anomalies with high confidence. However, because they mix up alarge number of behaviors, they tend to miss more subtle anomalies wherethe traffic is anomalous for the specific hosts involved.

On the other hand, very specific models such as those based on thetraffic between two hosts, or two groups of hosts, can be useful fordetecting more subtle anomalies that appear only in a specific context.However, very specific models can also suffer from low-samples effects,as there may be much less input data to assess. For example, a verygeneral model may assess all of the HTTP traffic for the local network,whereas a very specific model may assess HTTP traffic for only aparticular host in the local network. Thus, the very specific model maybe better able to identify subtle anomalies for the specific host, butalso have significantly smaller set of traffic data to assess. As aconsequence, finding the right scale at which to build statisticalmodels is difficult.

Hierarchical Models to Organize Learning Topologies

The techniques herein introduce a multi-scale method for network trafficanomaly detection on distributed learning agents, where modelscorresponding to different levels of aggregation and specificity arebuilt in parallel. In some aspects, all the output scores of thesemodels are then use to score input events in terms of how anomalous theyare. In addition, the capacity and dimensionality of machine learningmodels is adapted dynamically based on the performance and confidence ofthe models.

Specifically, according to one or more embodiments of the disclosure asdescribed in detail below, a device in a network maintains a pluralityof anomaly detection models for different sets of aggregated trafficdata regarding traffic in the network. The device determines a measureof confidence in a particular one of the anomaly detection models thatevaluates a particular set of aggregated traffic data. The devicedynamically replaces the particular anomaly detection model with asecond anomaly detection model configured to evaluate the particular setof aggregated traffic data and has a different model capacity than thatof the particular anomaly detection model. The device provides ananomaly event notification to a supervisory controller based on acombined output of the second anomaly detection model and of one or moreof the anomaly detection models in the plurality of anomaly detectionmodels.

Illustratively, the techniques described herein may be performed byhardware, software, and/or firmware, such as in accordance with the SLNprocess 248, which may include computer executable instructions executedby the processor 220 (or independent processor of interfaces 210) toperform functions relating to the techniques described herein, e.g., inconjunction with routing process 244.

Operationally, a first aspect of the multi-scale mechanism associatesinput traffic with model keys, based on a policy. This component caneither process raw network data (e.g., Netflow records, DPI records,other types of network records, etc.) and/or aggregated data (e.g.,features computed in time bins based on raw network data). In general, amodel key is an identifier of the model. A given chunk of input data, orbin of aggregated data, can be associated with multiple model keys. Forinstance, a Netflow or other traffic record, or aggregated traffic bin,could be associated to any or all of the following model keys:

-   -   Application classification of traffic    -   Source IP and application classification of traffic    -   Source MAC address and application classification of traffic    -   Destination IP and application classification of traffic    -   Destination MAC address and application classification of        traffic    -   Source IP, destination IP, and application classification of        traffic    -   Source MAC, destination MAC, and application classification of        traffic

Each model key represents a different level of aggregation and modeconstruction “scale”. In particular, the model keys can be selected in anon-uniform fashion. For instance, certain levels of aggregation may beless relevant for some application classification or hosts involved.

In another embodiment, model keys can also be constructed based ongroups (or, clusters) or hosts provided by an external system (e.g. acentral controller such as an SCA). In this context, IPs and MACaddresses can be mapped to groups, and additional model keys may beused, including:

-   -   Source group and application classification of traffic    -   Destination group and application classification of traffic    -   Source and destinations groups, and application classification        of traffic

As indicated above, these multiple scales allow for capturing differentlevels of anomalies with different levels of confidence.

FIGS. 5A-5E illustrate an example of a DLA dynamically swapping anomalydetection models, in accordance with various embodiments. In oneembodiment model keys may be pre-configured upon set up whereas inanother embodiment model keys may be built up on the fly upon requestsby a central controller using a custom model-key( ) message sent by thecentral controller to a DLA. For example, as shown in FIG. 5A, SCA 502may compute various model keys and install the model keys to DLA 400 viaa model_key( ) message 504. Such an approach allows for buildinggranular models that are specific to the criterion such as the DLAlocation, applications seen by the DLA, etc.

A second aspect of the multi-scale mechanism involves the constructionof statistical models for each model key, based on all the trafficrecords or aggregated traffic bins corresponding to these keys. Forexample, as shown in FIG. 5B, DLA 400 may use traffic data from thelocal network to construct anomaly detection models based on the modelkeys received from SCA 402. Any type of statistical model can be used,including approaches based on coding and reconstruction errors, densityestimators, or change point detection models. In particular, the modelsmay forget about the past at a rate that does or does not depend on theamount of traffic.

In one embodiment, the DLA may dynamically tune the modeling capacity ordimensionality of each statistical model, depending on the aggregationto which the model corresponds. In machine learning, capacity refers tothe ability of a model to capture complex behaviors. Although a highcapacity model allows to capture more, it is also much more prone toover fitting, as it can capture and model patterns that are just randomor due to noise. For instance, it may be desirable to use a highercapacity model for keys that aggregate a lot of traffic, in order tocapture more behaviors. In particular, model capacities anddimensionalities can be dynamically adjusted based on the number ofsamples per model, the past accuracies of models or other similarmetrics. A DLA may also decide not to build models for a given key ifthey are detected as unstable, lacking samples, etc., in which case acustom message model-status( ) may be used by the DLA to report modelstatus to the central controller. For example, as shown in FIG. 5C, DLA400 may determine that it does not have sufficient traffic data for agiven model key to construct a model. In turn, DLA 400 may notify SCA502 that the model cannot be constructed via a model_status( ) message506.

As shown in FIG. 5D, DLA 400 may dynamically swap models based on theircapacities and/or accuracies/confidence scores. For example, when theDLA determines that a given model is considered uncertain or inaccuratebased on the above metrics, the DLA may start up a lower capacity modelcorresponding to the same model keys. When the lower capacity model hasbeen trained, the previous model is deactivated, in one embodiment.Similarly, when a model has a very high confidence score, the DLA maystart up a higher capacity model in parallel as a substitute, and theprevious model is similarly retired when the new model is confidentenough.

In one embodiment, the size of the region of the models' input spacesthat is considered as anomalous may be estimated using statisticalmeans, and used to temporarily disable the production of scores frommodels where the anomalous region is tiny or empty. Indeed, some modelsmight degenerate to considering that most behaviors are normal, as mightbe the case, and the evaluation of this model is thus a waste ofcomputational power.

A third aspect of the multi-scale mechanism may monitor the outputscores from the models, and transform them into anomaly events that canbe forwarded to a global anomaly detection system. In particular, a DLAmay combine the outputs of its active models, and use the combinedoutputs to report anomaly events. For example, as shown in FIG. 5E, DLA400 may send a custom output_report( ) message 508 to SCA 502 that isbased on the combination of model outputs from the active models on DLA400.

DLA 400 may, based on an internal cost function, decide not to usescores from a model that is considered uncertain according to somestatistical metric (such as temporal changes in the model, or overallnumber of samples used to estimate the model). In addition, DLA 400 maytake into account the amount of samples in the models to provide a scorefor the corresponding anomalies. For instance, input that is anomalousfor aggregation levels such as “all the traffic corresponding to a givenaggregation” will be anomalous for all the model keys that are morespecific and can thus be considered to be a strong anomaly. On the otherhand, input that is anomalous only for a specific pair of hosts orgroups of hosts may be considered anomalous with less confidence, asthis stems from models that are very specific, and may just be a falsepositive.

DLA 400 may optionally take into account a variety of external feed-backsuch as signals from SCA 502 about qualities of anomalies for a givenkey. DLA 400 can store such feedback locally so as to keep track of therelevancy of anomalies on a per-model/per-key basis, in order to triggerappropriate action (e.g. cancel a model that is not efficient enough inorder to save CPU and memory resources). In yet another embodiment, theDLA may leverage an internal API to take memory and CPU resources intoaccount, to dynamically control the number of active models according totheir performance and the available local resources.

Distributed Architecture for Extreme Tracking of Anomaly Scores

As noted above, an anomaly detection system may use multiple statisticalor decision models by combining their scores to reach a final decision.In some cases, the most interesting anomalous events may only beanomalous for a handful of models or experts. This is in particular thecase for detection of anomalies from network traffic based onhierarchical models, as described above, where different models mayproduce scores on different mutually exclusive subsets of the inputtraffic. For instance, there may be only a subset of models that expressscores on a given type of application

a given application. In such cases, there may only be a handful ofmodels to express scores on a given chunk of traffic, and requiring manymodels to agree is unrealistic. This is unlike the common wisdom inother applications of such systems, where multiple models or expertsagreeing are the most important.

Additionally, combining many signals and models in the context ofanomaly decision may lead to a lot of anomalies, as considering moremodels increases the statistical odds that some of the input data may beconsidered anomalous by at least one of them. The generation of manyanomalous events is an issue in most anomaly detection systems andespecially in distributed systems where a very large number ofdistributed learning agents may each contribute anomalies. This isparticularly true when the decision of a single expert must beconsidered sufficient to deem an input anomalous. The challenge thatstems from these considerations is that of determining which events aremost rare in the context of many models, which may express scores ondifferent subsets of the input data.

In particular, the problem is even more acute in a distributed setting,where the models on each DLA might only have a partial view of whatevents are actually rare at the level of the full system. In addition,memory is usually very limited in distributed systems, and usuallyalready used for storing statistical models. A system for combining andregulating the scores of the models should thus use a very small amountof memory in this context. Similarly, a distributed sequential anomalydetection system usually has real-time processing requirements, andshould thus be efficient from a CPU perspective.

In various embodiments, further techniques are introduced that providean approach for regulating the production of anomalies from distributedmodels, both locally on the DLAs, and globally on a central controller(e.g., the SCA). More specifically, a system is introduced for trackingscores from multiple statistical models for anomaly detection on a DLA,and selecting the most anomalous events, both from the perspective ofthe scores seen locally, and of the scores received from other agents.The system groups the models by “buckets” where the models compete witheach other in terms of scores produced locally and globally, and modelscores that are low with respect to their assigned buckets are used toproduce anomalies. This process may proceed in an incremental fashion,by keeping a small state compared to the number of scores received.

Illustratively, the techniques described herein may be performed byhardware, software, and/or firmware, such as in accordance with the SLNprocess 248, which may include computer executable instructions executedby the processor 220 (or independent processor of interfaces 210) toperform functions relating to the techniques described herein, e.g., inconjunction with routing process 244.

Operationally, the anomaly detection system may track the output scoresof its underlying models, possibly produced on a DLA, and identify therarest events, both from the point of view of the agent and from aglobal point of view. In some aspects, a first aspect of the scoretracking mechanism may models in “buckets” of data. This componentmaintains a relationship between the models, and a smaller set ofbuckets, where each bucket corresponds to a set of models. A model maybe assigned to multiple bucket groups.

FIGS. 6A-6D illustrate an example of a DLA using model competitionbucket groups. The bucketing scheme can be used to create competitionbetween similar models, according to various embodiments. For example,very high-level models may be put in one bucket, while a set of morespecific models for a couple very specific devices and a given protocolmay be put in another bucket. This can be adjusted to the specifics ofthe anomaly detection problem considered. As shown in FIG. 6A, DLA 400may assign its various anomaly detection models to any number ofcompetition bucket groups.

In one embodiment, the bucketing can be modified dynamically based onfeedback from a central controller, such as SCA 502. In particular, aDLA may send summary statistics about the buckets, including the modelscurrently assigned to a bucket, or the samples and some summarystatistics about the scores contributed by each model to the bucket.This information may be used by the SCA to determine if the bucketsencode the desired competition structure between models.

In addition, the first component of the score tracking mechanism mayreceive and handle requests to dynamically reshape the buckets. Thefollowing two operations may be supported: (i) merging two buckets,and/or (ii) splitting a bucket in two new empty buckets. In the secondcase, any data assigned to the two buckets to fuse may either bediscarded, or be used to initialize the new buckets. For this, thedevices may send custom unicast/multicast messagesBucketsStatisticsRequest( ), BucketsStatistics( ), and BucketsReshape(), to request the summary statistics about the buckets, to send thesummary statistics about the buckets, and to perform the fuse/splitactions on buckets, respectively. For example, as shown in FIG. 6B, SCA502 may request bucket statistics/information from DLA 400 regarding itsmodel buckets using a BucketsStatisticsRequest( ) message 602. Inresponse, DLA 400 may return statistics regarding its bucket groups viaa BucketStatistics( ) message 604. In addition, as shown in FIG. 6C, SCA502 may determine that the buckets of DLA 400 should be adjusted andsend a BucketReshape( ) message 606 to DLA 400 to do so. As shown inFIG. 6D, DLA 400 may compare intra-bucket models to assess their outputscores.

For purposes of illustration only, examples of the score trackingmechanism are illustrated in FIGS. 7A-7C. In a first example shown inillustration 700 of FIG. 7A, consider a single model assigned to asingle bucket. In this special case, there is no competition, and thebucket mechanism acts primarily as a detector of extreme score valuesout of the model. Illustrations 710 shown in FIG. 7B illustrates thecase in which two or more models are assigned to the same competitionbucket group.

Another aspect of the score tracking mechanism may estimate the mostanomalous scores produced over a window by the models in each bucket, insome embodiments. The scores can be integrated into the bucket eitherimmediately, or after a predefined delay. In one embodiment, for eachbucket, the device may keep at most K score instances corresponding tothe K most anomalous scores seen in the bucket during a time window.Usually, anomalous scores are represented through high score values.This can be achieved through a simple list of the most anomalous scores,or through a more efficient data structure that maintains the scores ofthe bucket sorted.

The DLA may keep only the scores produced over a given time window bydiscarding the scores produced earlier than the time of the latest scoreminus the width of the time window. This requires a carefulconfiguration of K so that the number of scores kept in the trackerdoesn't fall excessively.

FIG. 7A illustrates the operation of the bucket mechanism in the singlemodel case with no competition and an infinite window. As shown, theinitial contents of the bucket are shown in panel A. After a scoreupdate, the bucket remains unchanged in panel B because the score is notanomalous enough to be in the top K. In panel C, a score that isanomalous enough has been observed. The lowest score (e.g., the leastanomalous in the set of most anomalous scores) is flushed out of thebucket, and the new score is added to the bucket.

FIG. 7B illustrates the behavior of the bucket approach in the two modelcase with competition and an infinite window. The initial contents ofthe bucket are shown in panel A. The bucket is then updated using scoresfrom both models. Only the score from model M1 is anomalous enough tomake it to the contents of the bucket. The same applies to the secondupdate. In this case, model M2 is never able to generate scores that areanomalous enough to update the bucket.

In another embodiment, for each bucket, the score tracking mechanismkeeps at most K scores instances corresponding to the most anomalousscores seen in the bucket during a time window, with the limitation thatonly the L most anomalous scores corresponding to a given key can bekept in the bucket. The function charged with selecting the scores ofinterest may either be locally configured on the DLA or dynamicallyupdated by an SCA with more complex policies (e.g., keep the K topscores over a period of time of H hours, allowing for K′>K if all scoresare higher than the 99 percentile computed over the past D days, etc.).

FIG. 7C illustrates the behavior of the above bucket mechanism in thesingle model case with an infinite window and L=1. For the illustration,lowercase letters are used as keys. The initial contents of the bucketare shown in panel A. After a score update, the bucket remains unchangedin panel B because the score is not anomalous enough to be in the top K.After another score update, the bucket still remains unchanged in panelC, because there is already a more anomalous score for the ‘a’ key. Inpanel D, a more anomalous score has been observed for the ‘a’ key, andreplaces the previous one in the bucket. Finally, in panel E, a scorecorresponding to a new key has been observed, and was sufficientlyanomalous to be kept in the bucket.

The key is additional information, orthogonal to the model, which isprovided with a score instance. For instance, a network traffic eventmay lead to multiple scores instances. In this embodiment, a key can beused to ensure that the network traffic event only occupies L slots inthe list of scores of the buckets at most. This can be adjusted to thespecifics of the anomaly detection problem considered.

A third aspect of the score tracking mechanism may send the contents ofthe buckets on the DLA along with other information such as the modelkeys, etc. to the SCA and/or receive such information from other DLAs orthe SCA. The devices may send most anomalous score reports for thebuckets either periodically or on request. To this end, the devices maysend custom unicast/multicast messagesBuckets_Most_Anomalous_Scores_Distributions_Request( ) andBuckets_Most_Anomalous_Scores_Distributions( ), to request the buckets'contents from another entity or send its buckets' contents,respectively.

FIGS. 8A-8B illustrate examples of a DLA sharing anomaly scoredistributions, in various embodiments. As shown in FIG. 8A, DLA 400 amay send a Buckets_Most_Anomalous_Scores_Distributions( ) message 802 toSCA 502 and/or any other DLA in the network, such as DLA 400 b, toreport its most anomalous scores for its buckets. Similarly, as shown inFIG. 8B, DLA 400 may send one or moreBuckets_Most_Anomalous_Scores_Distributions Request( ) messages 804 toSCA 502 or other DLAs, such as DLA 400 b, to request their mostanomalous scores.

A fourth aspect of the score tracking mechanism may receive scores fromthe models. For each score instance, the ranks of the score in thebuckets where the model is in are computed and aggregated using anaggregation function such as a minimum threshold. If the aggregate rankis below a threshold, an anomalous event is produced. In one embodiment,the ranks are computed only using the local buckets. In anotherembodiment, the ranks are computed using both the local buckets, and anymatching buckets that have been received through the

Buckets_Most_Anomalous_Scores_Distributions( ) message.

Dynamic Cooperation of DLAs

Also as noted above, it is paramount that DLAs are able to makeimmediate decisions as to whether traffic is suspicious, in order togather enough context about the offending traffic, and report theanomaly without delay. Gathering context may include gathering rawpacket data for the offending traffic, or any other traffic that isdeemed context-relevant by the system. In particular, this emphasizesthat decisions must be taken without much delay directly by the DLA, andthat systematically routing the data through the SCA or other DLAs isnot acceptable. Note that such issues are even exacerbated in systemssuch as in the IoT where DLAs are potentially connected to thecontroller/SCA via low-speed links with potentially intermittentconnectivity.

A common issue with DLAs is that they only have a partial view of thenetwork topology and traffic. For anomaly detection based on machinelearning, this can result in statistical models that have only beentrained on a limited amount of data. As a consequence, these “bird'seye” view models may have lower confidence or prediction accuracy thanmodels that would have been trained using more data, possibly frommultiple DLAs. This is especially true in systems that learn and makeuse of many targeted models, such as in the hierarchical architecturedescribed above. For instance, specific models may be built for DNSservers that are observed in the traffic for groups of desktop machinesor for remote cloud servers with which the local users are interacting.In particular, a specific model may also be built for a specificbusiness application, but the corresponding model may only get verylimited samples if the application is not used often by the local users.

The techniques herein further introduce an approach for dealing withlow-samples regimes and low-confidence models when doing anomalydetection using machine learning at the network edge. DLAs may eitherauto-assess their statistical models or have a controller (e.g., SCA)assess their statistical models. Such devices may be configured toidentify other DLAs that have compatible models, to enrich the localmodel of a given DLA. Notably, if bandwidth and utility constraints aremet, the compatible models may be requested and combined with the localmodel.

Illustratively, the techniques described herein may be performed byhardware, software, and/or firmware, such as in accordance with the SLNprocess 248, which may include computer executable instructions executedby the processor 220 (or independent processor of interfaces 210) toperform functions relating to the techniques described herein, e.g., inconjunction with routing process 244.

Operationally, the cooperation mechanism herein allows DLAs to exchangemodels between one another, in order to improve their real-timeprediction accuracy at almost no computational cost. A first componentof the cooperation mechanism may monitor the models on the DLAs, andassess whether some of them are insufficiently accurate or confident.For example, as shown in FIG. 9A, SCA 502 or another device (e.g., aparticular DLA, etc.) may receive model characteristics 902 from DLAs400 and 400 b.

In a first embodiment, a DLA may examine elements such as the amount ofsamples, the variance of the predictions, or possibly feedback from anSCA about previous anomalies signaled by the DLA. This is referred toherein as an auto-assessment mode.

In another embodiment, an SCA or other remote controller may perform theabove functionality, which may observe the models on the DLAs. Theexternal controller can take advantage of extra data, such as from otherDLAs, to determine accuracy and confidence measures for the models inrelation to those of other DLAs. This is referred to herein as therelative assessment mode.

In both embodiments, the assessments may be performed periodically for asubset of the models maintained at the DLA. The subset can be selecteddynamically based on a cost function depending on the time since thelast assessments, confidence metrics, or protocol-specific biases.

A second aspect of the cooperation mechanism may collect summarizednetwork characteristics from other DLAs, and can answer queries as towhether two DLAs are similar from the point of view of their networktraffic. In a first embodiment, a DLA itself may perform such functionsand may only answer queries as to whether another DLA is similar to theDLA. In a second embodiment, the SCA or other external device may answerany query regarding similarities. The answer to the query is providedunder the form of a similarity score, in one embodiment.

The cooperation mechanism allows the DLA or SCA to determine whethermodels from one DLA are relevant for use at another DLA. The networkcharacteristics may include summary statistics about the hosts seen bythe DLA, about the volume of traffic since at different scales by theDLA, or details about applications seen by the DLA (e.g., eitherapplication-classification levels metrics, or port and IP protocol-basedmetrics). In another embodiment, a statistical clustering model can belearned from the data provided by the various DLAs to the SCA. Onceproperly trained, the model can then be pushed to the DLAs, which maythen provide the model ID corresponding to the traffic class used foreach model. The SCA may then be able to determine which models may thenbe shared between DLAs.

In various embodiments, the devices may exchange unicast or multicastmessages, AgentSimilarQuery( ) and AgentSimilarReply( ) to querysimilarities. For example, as shown in FIG. 9B, DLA 400 may send anAgentSimilarQuery( ) message 904 to SCA 502, to identify any other DLAswith similar models. In response, as shown in FIG. 9C, SCA 502 mayindicate that DLA 400 b has one or more similar models to those of DLA400.

A third component of the cooperation mechanism may be a decision systemthat monitors models deemed uncertain by the above components anddecides whether other DLAs have compatible models to complement theincomplete model of the local DLA, and requests these models.

The third component of the cooperation mechanism can decide not torequests models, based on a cost function involving the output of thefirst component, the similarity with other agents, but also theimmediate and historical bandwidth impact. In particular, bandwidth capscan be fixed in order to avoid exchanging too many models at agents thatmostly have uncertain models. In addition, the cost function may also bebased in part on how often traffic corresponding to the model has beenseen in the past. In particular, a very uncertain model for anapplication for which only a couple packets have been seen may nottrigger a request to other agents to learn more. In some embodiments,unicast or multicast messages, AgentModelRequest( ) andAgentModelResponse( ) may be exchanged to query the models. For example,as shown in FIG. 9D, after DLA 400 determines that DLA 400 b hosts asimilar model, DLA 400 may send an AgentModelRequest( ) message 908 toDLA 400 b. In response, DLA 400 b may return the requested model to DLA400 via an AgentModelResponse( ) message 910.

In one embodiment gathering models is performed by a central controller(e.g., an SCA, etc.). In another embodiment, upon determining which DLAhost models related to traffic that have similar characteristics, theactual exchange of models may be performed using a distributed approach,with direct communication between DLAs. Such an approach allows for moreefficient bandwidth usage in the network and higher scalability.

FIG. 10 illustrates an example simplified procedure for using anomalydetection models, in accordance with various embodiments herein.Procedure 1000 may start at step 1005 and continues on to step 1010where, as described in greater detail above, a device in a network maymaintain a plurality of anomaly detection models. In some cases, thesemodels may be statistical models that analyze different sets ofaggregated traffic data from the network. For example, one model may bebased on both the source IP address of the traffic, as well as trafficassociated with a particular application. In contrast, another model maybe based on the destination MAC address of the traffic for theparticular application.

At step 1015, as detailed above, the device may determine a measure ofconfidence in one of the plurality of models. As would be appreciated,the device may calculate any number of confidence measures for aparticular model. For example, the device may calculate a statisticalconfidence value for a given statistical model.

At step 1020, the device may dynamically replace the particular modelwith another model, as described in greater detail above. In variousembodiments, the replacement model may have a different capacity thanthat of the model being replaced. For example, if the first model has alow confidence measure, the device may replace the first model with alower capacity model. Similarly, if the first model has a highconfidence measure, the device may opt to replace this model withanother model that has a higher capacity.

At step 1025, as detailed above, the device may provide an anomaly eventnotification to one or more other devices (e.g., an SCA). Such anotification may be based on a combination of model outputs from, e.g.,the replacement model from step 1020 and one or more of the other localmodels maintained by the device. In some cases, the device may selectonly those models with the highest n-number of confidence scores forcombination. In another embodiment, the device may base the selection onits own available resources, to dynamically adjust the number of modelsallowed to contribute to the notification. Procedure 1000 then ends atstep 1030.

It should be noted that while certain steps within procedure 1000 may beoptional as described above, the steps shown in FIG. 10 are merelyexamples for illustration, and certain other steps may be included orexcluded as desired. Further, while a particular order of the steps isshown, this ordering is merely illustrative, and any suitablearrangement of the steps may be utilized without departing from thescope of the embodiments herein.

The techniques described herein, therefore, provide a multi-scaleapproach allows the system to raise very strong anomalies with largeconfidence, as they may correspond to higher levels of aggregation, butalso more subtle anomalies with a lower confidence. Further aspects ofthe techniques herein allows for the selection of relevant events toraise anomalies using competition buckets for statistical models. Thisallows the system to avoid biases due to anomalies with large or lowflow volume or durations, as well as to avoid using an excessive amountof memory, which would be especially troublesome on embeddeddeployments. Finally, cooperation techniques are introduced herein thatallow proper predictions to be made in situations where some specificmodels have only low amounts of samples due to the location of the agentin the network, thus misrepresenting what can be observed over the fullnetwork. This potentially leads to false positives, wherein a behavioris scored as highly anomalous by the agent, while other agents would notagree.

While there have been shown and described illustrative embodiments thatprovide for anomaly detection, it is to be understood that various otheradaptations and modifications may be made within the spirit and scope ofthe embodiments herein. For example, while certain embodiments aredescribed herein with respect to using certain models for purposes ofanomaly detection, the models are not limited as such and may be usedfor other functions, in other embodiments. In addition, while certainprotocols are shown, such as BGP, other suitable protocols may be used,accordingly.

The foregoing description has been directed to specific embodiments. Itwill be apparent, however, that other variations and modifications maybe made to the described embodiments, with the attainment of some or allof their advantages. For instance, it is expressly contemplated that thecomponents and/or elements described herein can be implemented assoftware being stored on a tangible (non-transitory) computer-readablemedium (e.g., disks/CDs/RAM/EEPROM/etc.) having program instructionsexecuting on a computer, hardware, firmware, or a combination thereof.Accordingly this description is to be taken only by way of example andnot to otherwise limit the scope of the embodiments herein. Therefore,it is the object of the appended claims to cover all such variations andmodifications as come within the true spirit and scope of theembodiments herein.

What is claimed is:
 1. A method comprising: maintaining, at a device ina network, a plurality of anomaly detection models for different sets ofaggregated traffic data regarding traffic in the network; determining,by the device, a measure of confidence in a particular one of theanomaly detection models that evaluates a particular set of aggregatedtraffic data; dynamically replacing, by the device, the particularanomaly detection model with a second anomaly detection model configuredto evaluate the particular set of aggregated traffic data and has adifferent model capacity than that of the particular anomaly detectionmodel; and providing, by the device, an anomaly event notification to asupervisory controller based on a combined output of the second anomalydetection model and of one or more of the anomaly detection models inthe plurality of anomaly detection models.
 2. The method as in claim 1,further comprising: receiving, at the device and from the supervisorycontroller, data indicative of the types of sets of aggregated trafficdata that the device should model.
 3. The method as in claim 1, furthercomprising: dynamically adjusting, by the device, which outputs of theone or more anomaly detection models in the plurality of anomalydetection models should be combined with that of the second anomalydetection model based on available resource of the device.
 4. The methodas in claim 1, further comprising: assigning, by the device, a selectedfirst anomaly detection model from the plurality of anomaly detectionmodels to a competition bucket group; and determining, by the device, ananomaly detection score using the selected first anomaly detection modelassigned to the competition bucket group.
 5. The method as in claim 4,further comprising: assigning, by the device, a selected second anomalydetection model from the plurality of anomaly detection models to thecompetition bucket group; and determining, by the device, anomalydetection scores using the selected first and second anomaly detectionmodels assigned to the competition bucket group.
 6. The method as inclaim 5, further comprising: sending a report of the most anomalousscores, wherein the report of most anomalous scores limits the number ofanomaly scores that can be associated with any of the different sets ofaggregated traffic data.
 7. The method as in claim 1, furthercomprising: receiving, at the device, an indication of one or more nodesin the network that execute anomaly detection models that are similar tothat of the plurality of anomaly detection models maintained at thedevice; and combining, by the device, an anomaly detection model fromone or more of the nodes with one or more of the plurality of anomalydetection models maintained at the device.
 8. The method as in claim 7,further comprising: requesting, by the device, the indication of the oneor more nodes in response to a determination that one of the pluralityof anomaly detection models has a low confidence value.
 9. The method asin claim 1, wherein the aggregated traffic data aggregates one or moreof: an application classification of the traffic, a source address orport of the traffic, a destination address or port of the traffic, asource group of host devices associated with the traffic, or adestination group of host devices associated with the traffic.
 10. Anapparatus, comprising: one or more network interfaces to communicatewith a network; a processor coupled to the network interfaces andconfigured to execute one or more processes; and a memory configured tostore a process executable by the processor, the process when executedoperable to: maintain a plurality of anomaly detection models fordifferent sets of aggregated traffic data regarding traffic in thenetwork; determine a measure of confidence in a particular one of theanomaly detection models that evaluates a particular set of aggregatedtraffic data; dynamically replace the particular anomaly detection modelwith a second anomaly detection model configured to evaluate theparticular set of aggregated traffic data and has a different modelcapacity than that of the particular anomaly detection model; andprovide an anomaly event notification to a supervisory controller basedon a combined output of the second anomaly detection model and of one ormore of the anomaly detection models in the plurality of anomalydetection models.
 11. The apparatus as in claim 10, wherein the processwhen executed is further operable to: receive, from the supervisorycontroller, data indicative of the types of sets of aggregated trafficdata that the apparatus should model.
 12. The apparatus as in claim 10,wherein the process when executed is further operable to: dynamicallyadjust which outputs of the one or more anomaly detection models in theplurality of anomaly detection models should be combined with that ofthe second anomaly detection model based on available resource of theapparatus.
 13. The apparatus as in claim 10, wherein the process whenexecuted is further operable to: assign a selected first anomalydetection model from the plurality of anomaly detection models to acompetition bucket group; and determine an anomaly detection score usingthe selected first anomaly detection model assigned to the competitionbucket group
 14. The apparatus as in claim 13, wherein the process whenexecuted is further operable to: assign a selected second anomalydetection model from the plurality of anomaly detection models to thecompetition bucket group; and determine anomaly detection scores usingthe selected first and second anomaly detection models assigned to thecompetition bucket group.
 15. The apparatus as in claim 14, wherein theprocess when executed is further operable to: send a report of the mostanomalous scores, wherein the report of most anomalous scores limits thenumber of anomaly scores that can be associated with any of thedifferent sets of aggregated traffic data.
 16. The apparatus as in claim10, wherein the process when executed is further operable to: receive anindication of one or more nodes in the network that execute anomalydetection models that are similar to that of the plurality of anomalydetection models maintained at the apparatus; and combine an anomalydetection model from one or more of the nodes with one or more of theplurality of anomaly detection models maintained at the apparatus. 17.The apparatus as in claim 16, wherein the process when executed isfurther operable to: request the indication of the one or more nodes inresponse to a determination that one of the plurality of anomalydetection models has a low confidence value.
 18. The apparatus as inclaim 10, wherein the aggregated traffic data aggregates one or more of:an application classification of the traffic, a source address or portof the traffic, a destination address or port of the traffic, a sourcegroup of host devices associated with the traffic, or a destinationgroup of host devices associated with the traffic.
 19. A tangible,non-transitory, computer-readable medium storing program instructionsthat cause a device in a network to execute a process comprising:maintaining a plurality of anomaly detection models for different setsof aggregated traffic data regarding traffic in the network; determininga measure of confidence in a particular one of the anomaly detectionmodels that evaluates a particular set of aggregated traffic data;dynamically replacing the particular anomaly detection model with asecond anomaly detection model configured to evaluate the particular setof aggregated traffic data and has a different model capacity than thatof the particular anomaly detection model; and providing an anomalyevent notification to a supervisory controller based on a combinedoutput of the second anomaly detection model and of one or more of theanomaly detection models in the plurality of anomaly detection models.20. The tangible, non-transitory, computer-readable medium as in claim19, wherein the device is an edge router.